import { Button } from 'antd'
import React from 'react'
import { useNavigate } from 'react-router'
import './index.scss'

export default function HomeHeader() {

  const navigate = useNavigate()
  const userLogout = () => {
    sessionStorage.removeItem('token')
    navigate('/login')
  }
  return (
    <div className='header-com-box'>
      <div style={{width:"100px"}}>HomeHeader</div>
      <div style={{width:"80%"}} className="operlist">
        <Button color="#ffd561" variant="solid" onClick={userLogout}>退出登录</Button>
      </div>
    </div>
  )
}
